package com.tuanzi.loan.web.lazy.businesssystem;

import com.tuanzi.loan.business.service.businesssystem.BusinessProductService;
import com.tuanzi.loan.core.lazy.BaseLazyDataModel;
import com.tuanzi.loan.core.util.SpringContextHolder;
import com.tuanzi.loan.core.vo.PageSearcher;
import com.tuanzi.loan.vo.request.businesssystem.BusinessProductRequest;
import com.tuanzi.loan.vo.response.businesssystem.BusinessProductResponse;
import org.springframework.data.domain.Page;


public class BusinessProductLazyDataModel extends BaseLazyDataModel<BusinessProductRequest, BusinessProductResponse> {
    private BusinessProductService service = SpringContextHolder.getBean(BusinessProductService.class);
    public BusinessProductLazyDataModel(BusinessProductRequest request) {
        super(request);
    }
    @Override
    protected Page<BusinessProductResponse> doLoad(PageSearcher<BusinessProductRequest> pageSearcher) {
        return service.list(pageSearcher);
    }
}
